<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "https://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=11"/>
<meta name="generator" content="Doxygen 1.9.4"/>
<meta name="viewport" content="width=device-width, initial-scale=1"/>
<title>miniFOC: Function manual / 函数手册</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr id="projectrow">
  <td id="projectlogo"><img alt="Logo" src="Acme_LOGO.png"/></td>
  <td id="projectalign">
   <div id="projectname">miniFOC<span id="projectnumber">&#160;1.0.3</span>
   </div>
   <div id="projectbrief">This open-source project aims to accomplish a FOC(Field Oriented Control) scheme that is operatable with minimum costs in China.</div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.9.4 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search",'Search','.html');
/* @license-end */
</script>
<script type="text/javascript" src="menudata.js"></script>
<script type="text/javascript" src="menu.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() {
  initMenu('',true,false,'search.php','Search');
  $(document).ready(function() { init_search(); });
});
/* @license-end */
</script>
<div id="main-nav"></div>
</div><!-- top -->
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div><div class="header">
  <div class="headertitle"><div class="title">Function manual / 函数手册 </div></div>
</div><!--header-->
<div class="contents">
<div class="textblock"><p ><a class="anchor" id="md_E__Desktop_Files_Small_Projects_miniFOC_docs__mainpage"></a></p>
<h2><a class="anchor" id="autotoc_md1"></a>
Introduction / 简介</h2>
<p >&#160;&#160;&#160;&#160;This GitHub page is automatically generated by Doxygen according to code comments. It describes the purpose, function and usage of functions, variables and structures in each file except the library functions provided by gd32. You can click the "file - &gt; file list" button at the top of the page to jump to the file list to view the description of the variables and functions declared in the relevant files.</p>
<p >&#160;&#160;&#160;&#160;本Github Page由Doxygen根据代码注释自动生成，描述了除了GD32提供的库函数外的每个文件中函数、变量与结构体的用途、功能和用法。你可以通过点击页面上方的“File -&gt; File List”按钮跳转到文件列表以查看相关文件内部声明的变量和函数的说明。</p>
<h2><a class="anchor" id="autotoc_md2"></a>
Download and  Description / 下载与描述</h2>
<p >&#160;&#160;&#160;&#160;The content published below is the. Hex firmware generated by GitHub action scheduled task every time. The purpose is to automatically compile and publish the latest committed firmware under the main branch without manual compilation by the developer. It should be noted that the. Hex firmware on this page does not guarantee its stability and availability. If you want to download stable and available firmware, please go to the <a href="https://github.com/ZhuYanzhen1/miniFOC/releases">Release Page</a> to download it.</p>
<p >&#160;&#160;&#160;&#160;下面发布的内容是每次由Github Action定时任务生成的.hex固件，目的是自动编译发布main分支下最新commit的固件而无需开发者手动编译。需要注意的是，本页面下的.hex固件不保证它的稳定性和可用性。如果你想下载稳定可用的固件，请转到<a href="https://github.com/ZhuYanzhen1/miniFOC/releases">Release页面</a>下载。&#160;</p>
<ul>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202208/20220801.hex">20220801</a>: abed215 Add SVPWM modulation code, which can be controlled by using macros.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202205/20220524.hex">20220524</a>: dd0dbc8 Update cmake.yml</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202111/20211108.hex">20211108</a>: df8533c Change the automatic compilation workflow to run only when the push event occurs.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202111/20211107.hex">20211107</a>: bb8409a Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202111/20211106.hex">20211106</a>: 62c17af Merge branch 'main' of github.com:ZhuYanzhen1/miniFOC into main</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202111/20211105.hex">20211105</a>: 08164bb Merge remote-tracking branch 'origin/main' into main</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202111/20211104.hex">20211104</a>: 6a5dcd3 Added the button and method of flash writing content control. There are still problems with parameter reading and slider display that need to be modified.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202111/20211103.hex">20211103</a>: ef97f44 Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202111/20211102.hex">20211102</a>: b5687f6 Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202111/20211101.hex">20211101</a>: c459ea9 Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211031.hex">20211031</a>: 8e82bd1 Merge branch 'main' of github.com:ZhuYanzhen1/miniFOC into main</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211030.hex">20211030</a>: 8c464a0 Delete a piece of wire floating in the PCB. Generate and update coordinate files and Gerber files.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211029.hex">20211029</a>: c5ee9a1 Merge branch 'main' of github.com:ZhuYanzhen1/miniFOC into main</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211020.hex">20211020</a>: e1f4f51 Modify the GitHub action timed automatic compilation firmware to compile only when push occurs.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211012.hex">20211012</a>: 5aa44fc Merge remote-tracking branch 'origin/main' into main</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211011.hex">20211011</a>: 22d07b8 add two lables in monitor</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211010.hex">20211010</a>: 7520c1e Modify the main page of Doxygen generated documents to readme file as the main page.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211009.hex">20211009</a>: 1fdb661 Modify most of the files in the algorithm folder to a format recognized by Doxygen.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211008.hex">20211008</a>: 96d4344 Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211007.hex">20211007</a>: e1db21f Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211006.hex">20211006</a>: 8ff27a8 Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211005.hex">20211005</a>: 9e18ca4 Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202110/20211004.hex">20211004</a>: 9ad907a Correct the medium capacity data transfer protocol link in README.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210930.hex">20210930</a>: 62079a2 Merge branch 'main' of github.com:ZhuYanzhen1/miniFOC into main</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210929.hex">20210929</a>: 0ad9f00 Add comments for PID program.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210928.hex">20210928</a>: 6c3f43f Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210927.hex">20210927</a>: 4ef3bf9 Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210926.hex">20210926</a>: 13c4a77 Add the slider position and the maximum and minimum value change code for the monitor. Now the parameters of the motor can be parsed and reflected on the slider.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210925.hex">20210925</a>: 4c8ae1b Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210924.hex">20210924</a>: 00c7781 The problem of sending messages after the monitor is started has been solved. The problem of enabling logic of slider control in monitor is solved.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210923.hex">20210923</a>: bfeb755 Add the variable return function to sort out the uploaded functions into the report. C file.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210922.hex">20210922</a>: f3c4b4f Modify the development environment version in readme and add notes for the image repo.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210921.hex">20210921</a>: 5607792 Merge branch 'main' of github.com:ZhuYanzhen1/miniFOC into main</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210920.hex">20210920</a>: 06330fe Correct the FOC twice coordinate transformation annotation.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210919.hex">20210919</a>: 626c4fb Modify the global variable name so that it does not duplicate.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210918.hex">20210918</a>: 35eb651 Modify README and update mainwindow.ui of monitor</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210917.hex">20210917</a>: b5a9140 Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210916.hex">20210916</a>: 813b97e Add speed update configure macro to <a class="el" href="config_8h.html" title="used to place important parameter configurations for users">config.h</a>.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210914.hex">20210914</a>: 975d112 Update new firmware link to Github Pages</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210913.hex">20210913</a>: 3207bc9 The PCB circuit of minifoc is modified</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210912.hex">20210912</a>: 43bdf80 Fixed the problem that the reverse speed could not be measured during speed calculation.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210911.hex">20210911</a>: 610eeb6 Add a comment for timer deactivation.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210910.hex">20210910</a>: 97ade83 Modify the packet serial port sending function, and now you can send data correctly.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210909.hex">20210909</a>: 9216fd7 Add upper computer monitor tools for miniFOC</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210908.hex">20210908</a>: 0eef12c Normalize variable names and adjust the order.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210907.hex">20210907</a>: 238b89d Fix mdtp_callback_handler function name mismatch.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210906.hex">20210906</a>: 791bb85 Normalized FLASH read / write function name.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210905.hex">20210905</a>: be1d8fa The speed calculation code and sliding window filter function are added to make the speed smoother.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210904.hex">20210904</a>: 84aa5d8 Polish README</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210903.hex">20210903</a>: ebb2498 The electric angle correction program is added. The pole number and encoder resolution are added to the config file for modification. Corrected PWM initialization duty cycle to prevent power on burn out.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210902.hex">20210902</a>: 21ed3dd Add read and initialization functions of magnetic encoder. Add comments for SPI related functions and move SPI frequency division coefficient to config file for configuration.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202109/20210901.hex">20210901</a>: 2698c41 Merge branch 'main' of github.com:ZhuYanzhen1/miniFOC into main</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202108/20210831.hex">20210831</a>: 2d309e9 Code comments are added for fast mathematical calculation functions and FOC calculation functions.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202108/20210830.hex">20210830</a>: 021d7fa The fast mathematical calculation function is added to accelerate the calculation speed of sin and cos calculate, and the program volume is reduced (compared with using math Standard Library).</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202108/20210829.hex">20210829</a>: 1e40d66 Add and update PWM duty cycle function. Add comments for PWM initialization function and modify initialization channel.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202108/20210828.hex">20210828</a>: 0a068b2 Add wiki repo into docs directory</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202108/20210827.hex">20210827</a>: 924f307 Merge branch 'main' of github.com:ZhuYanzhen1/miniFOC into main</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202108/20210826.hex">20210826</a>: dfea67b Add the packet function of medium capacity transmission protocol. When the data packet is received, it is sent back according to the original packet to test whether the function of receiving and sending data packet can operate normally.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202108/20210825.hex">20210825</a>: 0e68071 Some data receiving functions are realized. Annotate the functions in the system file. Fixed missing systick handler. The memset function is rewritten, and the program volume can be reduced without using the standard library.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202108/20210824.hex">20210824</a>: 1b1fd54 Add UART0 initialization code, file author declaration, function declaration and code comments. Add config header file to facilitate users to modify important parameters.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202108/20210823.hex">20210823</a>: c774ad1 Add macro definition of LED level toggle.</li>
<li><a href="https://raw.githubusercontent.com/ZhuYanzhen1/miniFOC_Firmware/master/202108/20210822.hex">20210822</a>: c625232 Delete testing files </li>
</ul>
</div></div><!-- PageDoc -->
</div><!-- contents -->
<!-- start footer part -->
<hr class="footer"/><address class="footer"><small>
Generated by&#160;<a href="https://www.doxygen.org/index.html"><img class="footer" src="doxygen.svg" width="104" height="31" alt="doxygen"/></a> 1.9.4
</small></address>
</body>
</html>
